import React from "react";
import {Link,BrowserRouter,Route} from 'react-router-dom'
// import { Route } from "react-router-dom/cjs/react-router-dom.min";
import Home from './components/Home'
import About from './components/About'
export default class App extends React.Component{
 
  render(){
    return(
      <div>
        {/* BrowserRouter标签应该写入至index.js中可以一劳永逸 */}
        {/* <BrowserRouter>  */}
          <Link to='/about'>About</Link><br/>
          <Link to='/home'>Home</Link>
          <Route path='/about' component={About}/>
          <Route path='/Home' component={Home}/>
        {/* </BrowserRouter> */}
      </div>  
    )
  }
}